package com.sqx.modules.trendsLike.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 动态点赞
 *
 * @author wuChang
 * @since 2023-09-27
 */
@Data
@TableName("trends_like")
public class TrendsLike implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 记录id
     */
    @ApiModelProperty("记录id")
    @TableId(value = "like_id", type = IdType.AUTO)
    private Long likeId;

    /**
     * 动态id
     */
    @ApiModelProperty("动态id")
    private Long trendsId;

    /**
     * 用户id
     */
    @ApiModelProperty("用户id")
    private Long userId;
     /**
     * 被点赞的用户
     */
    @ApiModelProperty("被点赞的用户")
    private Long byUserId ;
    /**
     * 评论id
     */
    @ApiModelProperty("评论id")
    private Long commentId;

    /**
     * 创建时间
     */
    @ApiModelProperty("创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    /**
     * 被点赞是否已查看0否 1是
     */
    @ApiModelProperty("被点赞是否已查看0否 1是")
    private Integer isLook;
    /**
     * 用户昵称
     */
    @TableField(exist = false)
    @ApiModelProperty("用户昵称")
    private String userName;
    /**
     * 用户头像
     */
    @ApiModelProperty("用户头像")
    @TableField(exist = false)
    private String avatar;
    /**
     * 动态
     */
    @ApiModelProperty("动态")
    @TableField(exist = false)
    private String trendsContent;

}
